As programming approaches and foundations have evolved, application programming interfaces (APIs) and programming schemas have been developed to standardize and unify programming methodologies that were previously multi-variant and relatively incompatible. Modern programming therefore often involves employing APIs and schemas in conjunction with reusable libraries. Such Programming languages continue to evolve to facilitate specification by programmers as well as efficient execution.
Compilers and/or interpreters bear the burden of translating high-level logic into executable machine code. In general, compilers and/or interpreters are components that receive a program specified in a source programming language (e.g., C, C#, Visual Basic, Java...) and convert the logic provided thereby to machine language that is executable by a hardware device. However, the conversion need not be done verbatim. In fact, conventional compilers and/or interpreters analyze the source code and generate very efficient code. For example, programmers write code that sets forth a logical flow of operations that is intuitive and easy for humans to understand, but is often inefficient for a computer to execute. Compilers and/or interpreters can identify inefficiencies and improve program performance at the hardware level by eliminating unnecessary operations and/or rearranging the execution of instructions while still achieving the intended results. In this manner, programmers can create robust and efficient software.
Programming languages include static languages and dynamic languages. A static language requires most program structure—such as the types of variables and function arguments—to be determined at compile time. The compiler can detect errors and optimize performance at the cost of run-time flexibility. On the other hand, dynamic languages allow a user to make more run-time changes to program structure, such as passing arguments of different types to the same function and, in some languages, defining new types or classes. A dynamic environment can enable run-time definition and linking.
In general, type inference is a language mechanism that facilitates writing correctly typed applications for programmers. Consider the following:Dim X=“Hello”as a Visual Basic statement that both declares the variable X and initializes its value to the string “Hello”. The compiler is aware that the type of the right-hand side is String. Accordingly, the compiler can infer that the type of the variable ought to be X. Currently, the compiler sets the type of X to “Object”, the most general type in the language, and employs late binding to resolve later code like “X.Length( )”, which is only legal for type String.
Late binding refers to an operation wherein the compiler inserts code to look up the method “Length” at run time. Such ability to late-bound over member names is especially important in data-intensive programs where the structure of the data is not known statically, and for writing generic interpretative code. Nonetheless, late binding, while very flexible, can sometimes introduce run-time cost and reduce design-time hints in the user interface (e.g., when employing an assist provider such as Intellisense®.) Such can hinder flexibility of the programming languages.
Therefore, there is a need to overcome the aforementioned exemplary deficiencies associated with conventional systems and devices.